<?
$c = new ModuleConfig("");


// -- MessageResources --
$c->addMessageResourcesConfig(
    new MessageResourcesConfig(
        array(
            "parameter"=>"_application/resource/MessageResources",
            "nullValue"=>false
        )
    )
);


// -- Global Exceptions --
$c->addExceptionConfig(
    new ExceptionConfig(
        array(
            "type"=>"Exception",
            "path"=>"error/mvc/exception.php",
            "handler"=>"mvc/action/ExceptionHandler"
        )
    )
);
$c->addExceptionConfig(
    new ExceptionConfig(
        array(
            "type"=>"AccessDeniedException",
            "path"=>"error/mvc/forbidden.php",
            "handler"=>"mvc/action/ExceptionHandler"
        )
    )
);


// -- Redirects --
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/",
            "type"=>"mvc/action/RedirectAction",
            "forwards"=>array(
                "success"=>new ForwardConfig(
                    array(
                        "name"=>"success",
                        "path"=>"home",
                        "redirect"=>false
                    )
                )
            )            
        )
    )
);


// -- Forwards --
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/home",
            "forward"=>"home.php",
                        
        )
    )
);
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/login",
            "forward"=>"auth/login.php",
        )
    )
);
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/failed",
            "forward"=>"auth/login.php",
        )
    )
);
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/logout",
            "forward"=>"auth/logout.php",
        )
    )
);
$c->addActionConfig(
    new ActionConfig(
        array(
            "path"=>"/search",
            "forward"=>"search.php",
        )
    )
);


// -- Helpers --
$c->addHelperPath("_application/helper", "Application_View_Helper_");
$c->addHelperPath("mvc/view/helper", "PHP_MVC_View_Helper_");


return $c;
?>